//
//  BMSOpMergeEventBuilder.h
//  WDBMS
//
//  Created by YeJary on 2025/5/13.
//

#import <Foundation/Foundation.h>

NS_ASSUME_NONNULL_BEGIN

@interface BMSOpMergeEventBuilder : NSObject

/// 构造 m_data 上报数组（已编码为 JSON 字符串）
+ (NSString *)buildMDataWithEvents:(NSArray<NSDictionary *> *)events;

/// 构造一个用户行为事件 u_ac 示例
+ (NSDictionary *)event_userActionWithAct:(NSString *)act
                               description:(NSString *)desc
                                    tab1:(nullable NSString *)tab1
                                    tab2:(nullable NSString *)tab2
                                    tab3:(nullable NSString *)tab3
                                    tabN:(nullable NSDictionary<NSString *, NSString *> *)tabN;

/// 构造一个广告行为事件 ad_ac 示例
+ (NSDictionary *)event_adActionWithAct:(NSString *)act
                                   desc:(NSString *)desc
                                   tab1:(nullable NSString *)tab1
                                   tab2:(nullable NSString *)tab2
                                   tab3:(nullable NSNumber *)tab3
                                 adType:(nullable NSString *)adType;

/// 构造一个内购事件 iap 示例
+ (NSDictionary *)event_iapSuccessWithProductId:(NSString *)pid
                                    productName:(NSString *)name
                                     amountCent:(NSInteger)amount
                                        orderId:(NSString *)orderId
                                    productType:(nullable NSString *)type;

/// 构造一个用户信息事件 u 示例
+ (NSDictionary *)event_userInfoWithPlatform:(NSString *)platform
                                          os:(NSString *)os
                                        idfa:(nullable NSString *)idfa
                                        idfv:(nullable NSString *)idfv
                                        imei:(nullable NSString *)imei
                                  android_id:(nullable NSString *)androidId
                                         mac:(nullable NSString *)mac
                                        oaid:(nullable NSString *)oaid
                                          dm:(nullable NSString *)deviceModel
                                          ct:(nullable NSString *)countryCode
                                       ym_id:(nullable NSString *)ymId;

/// 构造一个用户操作数据事件 u_op 示例
/// - Parameters:
///   - act: 事件名
///   - desc: 事件属性
+ (NSDictionary *)event_userOpWithAct:(NSString *)act description:(NSString *)desc;

@end

NS_ASSUME_NONNULL_END
